﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.ComponentModel.Composition;
using System.Diagnostics;

namespace OnlineBookReader
{
    /// <summary>
    /// 
    /// </summary>
    [MetadataAttribute]
    [AttributeUsage(AttributeTargets.Class, AllowMultiple = false)]    
    public class DetailInfoAttribute : ExportAttribute,ISampleMetadata
    {
        public string Name { get; private set; }
        public string ViewName { get; private set; }
        /// <summary>
        /// 
        /// </summary>
        public DetailInfoAttribute(string name, string linkPath)
            : base("DetailInfo", typeof(FrameworkElement))
        {
            Debug.Assert(!string.IsNullOrEmpty(linkPath), "linkPath should not be empty!");
            Name = name;
            ViewName = linkPath;
        }
        public DetailInfoAttribute(string linkPath)
            : this(null, linkPath)
        { }
    }
}
